package com.lzg.okrx.adapter

import com.lzg.okrx.observable.BodyObservable
import com.lzy.okgo.adapter.AdapterParam
import com.lzy.okgo.adapter.Call
import com.lzy.okgo.adapter.CallAdapter

import io.reactivex.Observable

class ObservableBody<T> : CallAdapter<T, Observable<T>> {

    override fun adapt(call: Call<T>, param: AdapterParam?): Observable<T> =
        BodyObservable(AnalysisParams.analysis(call, param))

}
